export class tickTock {
  constructor(setMaxTime) {
    this._time = setMaxTime || 0;
    this._setinterval = 0;
    this._frequency = 1000;
  }

  set frequency(value) {
    this._frequency = Math.ceil(1000 / (value ? value : 1));
  }

  get frequency() {
    return;
  }

  pendulum(callback, ...arg) {
    this._setinterval = setInterval(() => {
      callback(...arg);
    }, this._frequency);
  }
}
